import request from '@/utils/request';
import { userData } from './login';

/**
 * 新增用户接口
 * @param data
 */
export function insertUser(data: userData): Promise<any> {
  return request('/sealCuttingApi/user/insertUser', {
    method: 'POST',
    data,
  });
}

/**
 * 修改用户接口
 * @param data
 */
export function updateUser(data: userData): Promise<any> {
  return request('/sealCuttingApi/user/updateUser', {
    method: 'POST',
    data,
  });
}

/**
 * 禁用用户接口
 * @param data
 */
export function disableUser(data: userData): Promise<any> {
  return request('/sealCuttingApi/user/disableOrEnableUser', {
    method: 'POST',
    params: data,
  });
}
